<?php
/* SVN FILE: $Id: default.ctp 7945 2008-12-19 02:16:01Z gwoo $ */
/**
 *
 * PHP versions 4 and 5
 *
 * CakePHP(tm) :  Rapid Development Framework (http://www.cakephp.org)
 * Copyright 2005-2008, Cake Software Foundation, Inc. (http://www.cakefoundation.org)
 *
 * Licensed under The MIT License
 * Redistributions of files must retain the above copyright notice.
 *
 * @filesource
 * @copyright     Copyright 2005-2008, Cake Software Foundation, Inc. (http://www.cakefoundation.org)
 * @link          http://www.cakefoundation.org/projects/info/cakephp CakePHP(tm) Project
 * @package       cake
 * @subpackage    cake.cake.libs.view.templates.layouts
 * @since         CakePHP(tm) v 0.10.0.1076
 * @version       $Revision: 7945 $
 * @modifiedby    $LastChangedBy: gwoo $
 * @lastmodified  $Date: 2008-12-18 18:16:01 -0800 (Thu, 18 Dec 2008) $
 * @license       http://www.opensource.org/licenses/mit-license.php The MIT License
 */

?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <?php echo $html->charset(); ?>
    <title>
        <?php __('CakePHP: the rapid development php framework:'); ?>
        <?php echo $title_for_layout; ?>
    </title>
    <?php
        echo $html->meta('icon');

        echo $html->css('cake.generic');
        echo $html->css('menu.fg' . DS . 'fg.menu');
        echo $html->css('jquery.ui' . DS . 'black.tie' . DS . 'jquery.ui');

        echo $javascript->link('jquery' . DS . 'jquery.min');
        echo $javascript->link('menu.fg' . DS . 'fg.menu');

        echo $scripts_for_layout;
    ?>
    <script type="text/javascript">
        $(function(){
            // BUTTONS
            $('.fg-button').hover(
                function(){ $(this).removeClass('ui-state-default').addClass('ui-state-focus'); },
                function(){ $(this).removeClass('ui-state-focus').addClass('ui-state-default'); }
            );

            // MENUS
            $.get('./files/menu_content.html', function(data){ // grab content from another page
                $('#flyout').menu({ content: data, backLink: false });
            });

            <?php
            if ($session->check('Message.flash')):
            ?>
            $(window).load(function(){
                setTimeout(function(){ $('.flash_box').fadeOut('slow') }, 1000);
            });
            <?php
            endif;
            ?>
        });
    </script>
    <style type="text/css">
        body { font-size:62.5%; margin:0; padding:0; }
        #menuLog { font-size:1.4em; margin:20px; }
        .hidden { position:absolute; top:0; left:-9999px; width:1px; height:1px; overflow:hidden; }

        .fg-button { clear:left; margin:0 4px 40px 20px; padding: .4em 1em; text-decoration:none !important; cursor:pointer; position: relative; text-align: center; zoom: 1; }
        .fg-button .ui-icon { position: absolute; top: 50%; margin-top: -8px; left: 50%; margin-left: -8px; }
        a.fg-button { float:left;  }
        button.fg-button { width:auto; overflow:visible; } /* removes extra button width in IE */

        .fg-button-icon-left { padding-left: 2.1em; }
        .fg-button-icon-right { padding-right: 2.1em; }
        .fg-button-icon-left .ui-icon { right: auto; left: .2em; margin-left: 0; }
        .fg-button-icon-right .ui-icon { left: auto; right: .2em; margin-left: 0; }
        .fg-button-icon-solo { display:block; width:8px; text-indent: -9999px; }     /* solo icon buttons must have block properties for the text-indent to work */

        #.fg-button.ui-state-loading .ui-icon { background: url(./img/menu.fg/spinner_bar.gif) no-repeat 0 0; }
    </style>
</head>
<body>
    <div id="container">
        <div id="header">
            <h1><?php echo $html->link(__('CakePHP: the rapid development php framework', true), 'http://cakephp.org'); ?></h1>
        </div>
        <div id="menu">
            <a tabindex="0" class="fg-button fg-button-icon-right ui-widget ui-state-default ui-corner-all" id="flyout">
                Flyout Menu<span class="ui-icon ui-icon-triangle-1-s"></span>
            </a>
        </div>
        <div id="content">
            <?php
                if ($session->check('Message.flash')):
                    $session->flash();
                endif;
            ?>
            <?php echo $content_for_layout; ?>
        </div>
        <div id="footer">
            <?php echo $html->link(
                    $html->image('cake.power.gif', array('alt'=> __("CakePHP: the rapid development php framework", true), 'border'=>"0")),
                    'http://www.cakephp.org/', array('target'=>'_blank'), null, false
                );
            ?>
        </div>
    </div>
    <?php echo $cakeDebug; ?>
</body>
</html>
